<template>

    <z-paging ref="paging" v-model="dataList" @query="queryList" :default-page-size="20">
		<!-- <template #top>
		         <view >
		            
		        11
		         </view>
		       </template> -->
        <view class="item" v-for="(item,index) in dataList" :key="index">
            
	 <fui-card   :title="item.vipTitle" :tag="'¥'+item.totalFee">
	 	<view class="fui-card__content">{{item.description}}</view>
		<view class="fui-card__content">
			<text style="float: right;" @click="openDialog(item.id)"> 开通会员</text>
	   </view>
		 
	 </fui-card>
			  
        </view>
		
		
    </z-paging>
	

</template>

<script>
    export default {
        data() {
            return {
				// v-model绑定的这个变量不要在分页请求结束中自己赋值，直接使用即可
                dataList: [],
			           param:{
			             phonenumber:'',
			             nickName:'',
			             outTradeNo:'',
			             transactionId:'',
			             userId:''
			           }
            };
        },
		onLoad() {
	 
			 let user=uni.getStorageSync("user")
			 this.param.userId=user.userId;
		},
        methods: {
			// @query所绑定的方法不要自己调用！！需要刷新列表数据时，只需要调用this.$refs.paging.reload()即可
            queryList(pageNo, pageSize) {
		 
				 this.$request.post('order/list', {pageNum:pageNo,pageSize:pageSize,param:this.param}).then(res => {
				 	 this.$refs.paging.complete(res.data.dataList);
				 }).catch(res => {
                	 
                	this.$refs.paging.complete(false);
                })
            },
      
		
		
 },
	
    };
</script>

<style>



	.fui-text__explain {
		font-size: 28rpx;
		color: #7F7F7F;
		flex-shrink: 0;
	}

 
</style>